<!--
*Author：富行天下团队

 *代码由框架生成,任何更改都可能导致被代码生成器覆盖
 *业务请在@/extension/Mall/Small_user_distributors.js此处编写
 -->
<template>
  <div>
    <view-grid ref="grid" :columns="columns" :detail="detail" :editFormFields="editFormFields" :editFormFileds="editFormFields" :editFormOptions="editFormOptions"
      :searchFormFields="searchFormFields" :searchFormFileds="searchFormFields" :searchFormOptions="searchFormOptions" :table="table" :extend="extend">
    </view-grid>
  </div>
</template>

<script>
import extend from '@/extension/mall/Small_user_distributors.js'
import ViewGrid from '@/components/basic/ViewGrid.vue'
var vueParam = {
  components: {
    ViewGrid,
  },
  data() {
    return {
      table: {
        key: 'id',
        footer: 'Foots',
        cnName: '分销员审核',
        name: 'Small_user_distributors',
        url: '/Small_user_distributors/',
        sortName: 'createDate',
      },
      extend: extend,
      editFormFields: {},
      editFormOptions: [],
      searchFormFields: { name: '', phone: '', status:"" },
      searchFormOptions: [
        [
          { title: '姓名', field: 'name', type: 'like' },
          { title: '手机号', field: 'phone', type: 'like' },
          { title: '状态', field: 'status', type: 'select',dataKey:'distributionStatus',data:[] },
        ],
      ],
      columns: [
        { field: 'head_img', title: '头像', type: 'img', width: 120, align: 'left' },
        { field: 'id', title: 'id', type: 'int', width: 90, hidden: true, readonly: true, require: true, align: 'left' },
        //    {field:'merchantCode',title:'新商户编号',type:'string',width:120,align:'left'},
        //    {field:'merchantName',title:'新商户名称',type:'string',width:120,align:'left'},
        { field: 'name', title: '姓名', type: 'string', width: 120, align: 'left' },
        { field: 'phone', title: '手机号', type: 'string', width: 160, align: 'left' },
        { field: 'nickname', title: '昵称', type: 'string', width: 90, align: 'left' },
        { field: 'grade', title: '等级', type: 'string', bind: { key: 'sharelevel', data: [] }, width: 90, align: 'left' },
        //    {field:'achievement',title:'直推分销业绩',type:'string',width:120,align:'left',sortable:true},
        { field: 'commission', title: '累计佣金', type: 'decimal', width: 90, align: 'left' },
        { field: 'consumption', title: '消费金额', type: 'decimal', width: 90, align: 'left' },
        //    {field:'distributors_id',title:'商户id',type:'string',width:220,align:'left'},
        //    {field:'numberofdistributors',title:'一级分销商人数',type:'int',width:90,align:'left'},
        //    {field:'numberofusers',title:'一级用户人数',type:'int',width:90,align:'left'},
        { field: 'parentname', title: '上级名称', type: 'string', width: 90, align: 'left' },
        { field: 'parentphone', title: '上级手机号', type: 'string', width: 160, align: 'left' },
        //    {field:'status',title:'状态0未审核,1同意,2驳回',type:'int',width:90,align:'left'},
        { field: 'creator', title: '创建人名称', type: 'string', width: 180, align: 'left' },
        { field: 'createDate', title: '创建时间', type: 'datetime', width: 90, align: 'left', sortable: true },
      { field: 'modifier', title: '修改人名称', type: 'string', width: 180, align: 'left' },
        //    {field:'modifierID',title:'修改人id',type:'int',width:90,align:'left'},
        { field: 'modifyDate', title: '修改时间', type: 'datetime', width: 90, align: 'left', sortable: true },
        //    {field:'createID',title:'创建人id',type:'int',width:90,hidden:true,align:'left'},
      ],

      detail: {
        cnName: '#detailCnName',
        columns: [],
        sortName: '',
        key: '',
      },
    }
  },
}
export default vueParam
</script>
